#ifndef _SYSTEM_H_
#define _SYSTEM_H_

#include "base.h"


#define SYSCALL			64

/*
  *  system vertor
  */
enum{
	SYS_INVALID = 0,

	SYS_CUR_PROC,
	SYS_FORK,					/* pid_t fork(); */
	SYS_KILL,					/* int kill(int proc,int sig) */
	SYS_SELF_SUSPEND,
	SYS_SUSPEND,
	SYS_EXIT,					/* void exit(int status)	 */
	SYS_EXEC,
	SYS_TIME,					/* time_t time(time_t *tp) */
	SYS_SLEEP,					/* int sleep(unsigned int sleep_sec) */
	SYS_WRITE,					/* ssize_t write(int fd, void *buffer, size_t) */
	SYS_READ,					/* ssize_t read(int fd, void *buffer, size_t) */
	SYS_MALLOC,				/*void *malloc(unsigned int num_bytes); */
	SYS_FREE,

	SYS_MAX
};

struct syscall_t{
	uint_32 syscall_nr;
	uint_32 p1;
	uint_32 p2;
	uint_32 p3;
	uint_32 p4;
	uint_32 p5;
	uint_32 p6;
	uint_32 p7;
};
#endif
